import { Entity, Code, Cover, CreateDate, Date, DateTime, Digdit, Email, Jsonb, Latlng, PrimaryUuid, RichText, Star, Tags, Telephone, Text, Title, UpdateDate, Year, Desc } from "@sker/core";

@Entity({
    name: 'jd_hotel'
})
export class JdHotel {
    @PrimaryUuid()
    id: string;

    @Code({
        nullable: true,
        comment: '提供方'
    })
    from: string;

    @Title({
        nullable: true,
        comment: '名称'
    })
    name: string;

    @Title({
        nullable: true,
        comment: '名称中文'
    })
    name_cn: string;

    @Title({
        nullable: true,
        comment: '地址'
    })
    address: string;

    @Title({
        nullable: true,
        comment: '地址中文'
    })
    address_cn: string;

    @Code({
        nullable: true,
        comment: '城市编码'
    })
    citycode: string;

    @Title({
        nullable: true,
        comment: '城市'
    })
    cityname: string;

    @Title({
        nullable: true,
        comment: '城市中文'
    })
    cityname_cn: string;

    @Code({ nullable: true, comment: '国家编号' })
    countrycode: string;

    @Title({ nullable: true, comment: '国家' })
    countryname: string;

    @Title({
        nullable: true,
        comment: '国家中文'
    })
    countryname_cn: string;

    @Code({
        nullable: true,
        comment: '目的地id'
    })
    destinationid: string;

    @Title({ nullable: true, default: '目的地' })
    destinationname: string;

    @Title({ nullable: true, default: '目的地中文' })
    destinationname_cn: string;

    @Star({ default: 0, comment: '星级评定' })
    starrating: number;

    @Telephone({
        nullable: true,
        comment: '电话'
    })
    telephone: string;

    @Email({ nullable: true, comment: '邮箱' })
    email: string;

    @Code({ nullable: true, comment: '品牌' })
    brand: string;

    @Code({ nullable: true, comment: '主题' })
    theme: string;

    @Cover({ nullable: true, comment: '缩略图' })
    cover: string;

    @Code({ nullable: true, comment: '类型' })
    category: string;

    @Jsonb({ nullable: true, default: [], comment: '酒店图集' })
    images: { title: string, url: string }[];

    @Jsonb({ nullable: true, default: [], comment: '酒店标签' })
    tags: string[];

    @Jsonb({ nullable: true, default: [], comment: '支付方式' })
    pay_ways: string[];

    @Text({ nullable: true, comment: '特殊提示' })
    tooltip: string;

    @Jsonb({ nullable: true, default: [], comment: '政策' })
    policies: any[];

    @Jsonb({ nullable: true, default: [], comment: '设施' })
    facilities: any[];

    @Digdit({ default: 0, comment: '评论数量' })
    comment_count: number;

    @Digdit({ default: 0, comment: '评价星级' })
    comment_star: number;

    @Digdit({ default: 0, comment: '环境评价星级' })
    comment_env_star: number;

    @Digdit({ default: 0, comment: '卫生评价星级' })
    comment_health_star: number;

    @Digdit({ default: 0, comment: '服务评价星级' })
    comment_service_star: number;

    @Digdit({ default: 0, comment: '设施评价星级' })
    comment_facilities_star: number;

    @Desc({ nullable: true, comment: '简介' })
    desc: string;

    @Desc({ nullable: true, comment: '简介中文' })
    desc_cn: string;

    @RichText({ nullable: true, comment: '酒店介绍' })
    content: string;

    @RichText({ nullable: true, comment: '酒店介绍中文' })
    content_cn: string;

    @Latlng({ nullable: true, comment: '经纬度' })
    latlng: any;

    @Code({ nullable: true, comment: '邮政编码' })
    zipcode: string;

    @Code({
        nullable: true, comment: '状态编码'
    })
    statecode: string;

    @Code({ nullable: true, comment: '机场代号' })
    airportcode: string;

    @DateTime({ comment: '酒店更新时间' })
    hotel_update_date: Date;

    @Date({ nullable: true, comment: '开业' })
    open_year: string;

    @Date({ nullable: true, comment: '装修' })
    fix_year: string;

    @Digdit({ default: 0, comment: '客房数' })
    room_count: number;

    @Jsonb({ nullable: true, comment: '支持房型' })
    room_type: string[];

    @Jsonb({ nullable: true, comment: '房间' })
    rooms: any[];

    @CreateDate({ comment: '创建时间' })
    create_date: Date;

    @UpdateDate({ comment: '更新时间' })
    update_date: Date;
}
